home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Champak 120
/
Vol 120.iso
/
games
/
bounce_c.swf
/
scripts
/
DefineSprite_268_bombDrop
/
frame_2
/
DoAction.as
Wrap
Text File
|
2010-11-09
|
574b
|
27 lines
this._rotation = Math.random() * 360;
this.exploded = true;
if(_root.sound_on == true)
{
trapDiffY = 275 - this._y;
if(trapDiffY < 0)
{
trapDiffY = - trapDiffY;
}
trapDiffY /= 10;
trapDiffX = 200 - this._x;
if(trapDiffX < 0)
{
trapDiffX = - trapDiffX;
}
trapDiffX /= 10;
trapVolume = 100 - trapDiffX - trapDiffY;
if(trapVolume < 10)
{
trapVolume = 10;
}
boomSound = new Sound(this);
boomSound.attachSound("fxExplode");
boomSound.start(0,1);
boomSound.setVolume(trapVolume);
}